<template>
  <div id="app">
    <el-container>
      <!-- 侧边栏 -->
      <Sidebar />
      <!-- 主内容区域 -->
      <el-container class="main-container">
        <el-main class="main-content">
          <router-view />
        </el-main>
      </el-container>
    </el-container>
  </div>
</template>

<script setup>
import Sidebar from './components/Sidebar.vue'
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: #2c3e50;
  margin: 0;
  padding: 0;
}

/* 主容器：与侧边栏宽度保持一致的左侧边距 */
.main-container {
  margin-left: 200px; /* 等于侧边栏宽度，避免内容被遮挡 */
}

.main-content {
  padding: 20px;
  min-height: 100vh; /* 高度占满视口 */
}
</style>
    